package com.hzx.dao;

import com.hzx.pojo.Commodity;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CommodityMapper {

    Integer deleteByPrimaryKey(Integer id);

    Integer insert(Commodity record);

    Integer insertSelective(Commodity record);

    Commodity selectByPrimaryKey(Integer id);

    Integer updateByPrimaryKeySelective(Commodity record);

    Integer updateByPrimaryKey(Commodity record);

    Commodity selectByName(String name);

    Commodity selectByPrice(double price);

    Commodity selectByKid(Integer kid);

    Commodity selectByUid(Integer uid);

    Commodity selectByid(Integer id);

    Integer selectIdBySelective(Commodity commodity);

    Integer selectIdByUidAndDate(Commodity commodity);

    Integer selectIdByUid(Integer uid);

    List AllCommodity();

    List selectCommodityByUid(Integer uid);

    Integer getNumbsByKindId(Integer id);

    Integer selectcommodityNum();

    Integer selectCommodityTradeNum();

    Integer updateCommodityStatus(Integer id);

    List selectByKidAndPrice(Integer kid, Integer lo, Integer he);
}
